<div class="smart-rightPanel layui-form">
    <div class="layui-anim layui-anim-upbit">
        <blockquote class="site-text layui-elem-quote">

        </blockquote>
        <table id="list_table" class="layui-hide" lay-filter="mainList"></table>
    </div>
</div>
<script>
    layui.use(['layer', 'table', 'form','jquery'], function () {
        var layer = layui.layer;
        var table = layui.table;
        var form = layui.form;
        var  $ = layui.jquery;
        var tableObj = table.render({
            id: 'list_table'
            , elem: '#list_table'
            , url: 'buss/daka/log'
            , where:{id:getHashParam().id,dakaId:getHashParam().dakaId}
            , align: "center"
            , cols: [[ //表头
                {field: 'id', title: '编号',align: 'center',hide:true}
                , {field: 'userName', title: '用户名',  align: 'center' , templet: function (d) {
                        return '<a class="font-primary" href="views/index.html#/buss/user/list[id='+d.userId+']">'+d.userName+'</a>'
                    }}
                , {field: 'createDate', title: '打卡时间',  align: 'center'}
                , {field: 'dakaId', title: '期号',  align: 'center'}
                , {field: 'daka', title: '打卡金额', align: 'center'}
                , {field: 'paifa', title: '奖励金额', align: 'center'}
                , {field: 'dakaStatus', title: '奖励金状态',  align: 'center', templet: function (d) {
                        if(d.dakaStatus==0){
                            return '未计算';
                        }else if(d.dakaStatus==1){
                            return '已计算';
                        }else if(d.dakaStatus==2){
                            return '已领取';
                        }else if(d.dakaStatus==3){
                            return '未领取';
                        }
                    }}

            ]]
            , done :function(res,curr,count){
                $(".layui-table-box").find("[data-field='id']").css("display","none");
            }
        });

        $("#search").click(function () {
            reloadTable(tableObj);
        });


    });
</script>

